// The Vue build version to load with the `import` command
// (runtime-only or standalone) has been set in webpack.base.conf with an alias.
import Vue from 'vue'
import FastClick from 'fastclick'
import VueRouter from 'vue-router'
import App from './App'

// import Vconsole from 'vconsole'

// let vConsole = new Vconsole()
//
// Vue.use(vConsole)

// import JsBridge from '@/service/common/GZBJSBridge'
// Vue.prototype.$bridge = JsBridge

import router from './router/index'
import './assets/css/font-awesome/css/font-awesome.min.css'
import './assets/css/weui/weui.css'
import './assets/css/form.css'
// 导入 表单模板扩展样式
import "./assets/css/extend/formExtend.less"
// 新UI规范化组件样式
import "./assets/css/extend/gzStyle.less"
// 导入 不同色系扩展样式
import "./assets/css/extend/seriesStyle.less"

// vant部分引入插件
import Vant from 'vant';
// vant样式库
import 'vant/lib/index.css';
Vue.use(Vant)


// import BaiduMap from 'vue-baidu-map'
 
// Vue.use(BaiduMap, {
//   ak: 'JKkVSzSb3qe4TtG0dGbdGpKVWyA145Do' // 替换成你自己的百度地图开发密钥
// })

import AbJwtSetting from './service/common/ab-jwt-setting'
import BaseService from './service/common/baseService'
import Tools from './service/common/tools'


import { LoadingPlugin,Marquee, MarqueeItem,ToastPlugin, AlertPlugin,GroupTitle,Cell, Grid,GridItem,XHeader,Popup,TransferDom,XSwitch, Tabbar, TabbarItem,Loading,Flexbox, FlexboxItem,XDialog,Divider, Card,Badge,Popover,ConfirmPlugin,Checker, CheckerItem } from 'vux'
// import  recognize from "@/view/auth/recognize"
Vue.use(LoadingPlugin)
Vue.use(AlertPlugin)
Vue.use(ToastPlugin)
Vue.use(ConfirmPlugin)
Vue.component('checker-item', CheckerItem)
Vue.component('checker', Checker)
// Vue.component('recognize', recognize)

Vue.component('x-header', XHeader)
Vue.component('grid', Grid)
Vue.component('grid-item', GridItem)
Vue.component('group-title', GroupTitle)
Vue.component('cell', Cell)
Vue.directive('transfer-dom', TransferDom)
Vue.component('x-switch', XSwitch)
Vue.component('tabbar', Tabbar)
Vue.component('tabbar-item', TabbarItem)

Vue.component('popup', Popup)
Vue.component('x-dialog', XDialog)

Vue.component('flexbox', Flexbox)
Vue.component('flexbox-item', FlexboxItem)
Vue.component('divider', Divider)
Vue.component('card', Card)
Vue.component('badge', Badge)
Vue.component('popover', Popover)

Vue.component('marquee', Marquee)
Vue.component('marqueeItem', MarqueeItem)


//Vue.use(Vuex)
Vue.use(VueRouter)

Vue.use(AbJwtSetting)
// util 和baseService 直接注入到Vue上
Vue.use(Tools)
Vue.use(BaseService)
// seesion 过期弹框登录
// import login from '@/components/user/loginDialog.vue'
// Vue.use(login)

//注册AbScroller
// import AbScroller from '@/components/form/abScroller.vue';
// Vue.component('abScroller', AbScroller);
// //注册AbCustDialog
// import AbCustDialog from '@/components/form/abCustDialog.vue';
// Vue.component('abCustDialog', AbCustDialog);
// //注册AbSerialNo
// import AbSerialNo from '@/components/form/abSerialNo.vue';
// Vue.component('abSerialNo', AbSerialNo);

// import AbEasyCost from '@/components/form/abEasyCost.vue'
// Vue.component('abEasyCost',AbEasyCost)

// import { VueJsonp  } from 'vue-jsonp'
// Vue.use(VueJsonp) // $jsonp被挂载到vue原型上

//复制内容到剪切板插件
// import VueClipboard from "vue-clipboard2";
//对接小程序开放平台js
import api from '@/api/api.js'
Vue.prototype.$api = api
window.$api = api
// Vue.use(VueClipboard)
// 引l入 vconsole
// import vconsole from'vconsole'
// new vconsole()
// if(process.env.NODE_ENV =='development'){
//   const vconsole =require('vconsole')
//   //eslint-disable-next-line no-newnew
//   new vconsole()
// }
FastClick.attach(document.body)

Vue.config.productionTip = false

/* eslint-disable no-new */
new Vue({
  router,
  render: h => h(App)
}).$mount('#app-box')
